package domd6;

import java.util.Scanner;

public class Main {
    public double[] func(int[] age,int n) {
        int a=0,b=0,c=0,d=0;//用来统计每个年龄段的人数多少
        for (double x :age) {
            if(x>0&&x<=18){
                a++;
            }else if(x>=19&&x<=35){
                b++;
            }else if(x>=36&&x<=60){
                c++;
            }else {
                d++;
            }
        }
        //返回每个年龄段病人的概率
        return new double[]{100.0* a / n, 100.0 * b / n, 100.0 * c / n, 100.0 * d / n};
    }

    public static void main(String[] args) {
        Main f=new Main();
        Scanner input=new Scanner(System.in);
        int n=input.nextInt();//病人的人数
        int[] arrays=new int[n];
        for (int i = 0; i <arrays.length; i++) {
            arrays[i]=input.nextInt();
        }
       double[] array= f.func(arrays,n);
        System.out.printf("%.2f%%\n%.2f%%\n%.2f%%\n%.2f%%", array[0], array[1], array[2], array[3]);
    }
}
